package org.phantom.securityframework.datapermission;

import java.lang.annotation.Annotation;

import org.phantom.securityframework.api.exception.AnnotationConfigureException;

/**
 * 数据提供器,数据由此接口进行过滤
 * @author apple
 *
 */
public interface DataProvider {

	/**
	 * 查询数据
	 * @param args
	 * @return
	 */
	public Object provide(Object[] args,Annotation anno)throws AnnotationConfigureException;
	/**
	 * 查询总大小
	 * @param args
	 * @return
	 */
	public int total(Object[] args,Annotation anno)throws AnnotationConfigureException;
	/**
	 * 构造查询参数
	 * @param args
	 * @return
	 */
	public DimensionQuery createDimensionQuery(Object[] args,Annotation anno);
}
